export type IEnv = 'local' | 'dev' | 'test' | 'uat' | 'prod' | 'hotfix' | 'feature-1' | 'feature-2';

type IConfig = {
  [key in IEnv]: {
    baseURL: string;
    env: IEnv;
    [key: string]: any;
  };
};

const config: IConfig = {
  local: {
    // TODO: 本地调试时的 API 环境。若为 ‘/' ，则会走 proxy
    baseURL: 'https://api-gateway-feature-1.ab-inbev.cn',
    env: 'local',
  },
  dev: {
    baseURL: 'https://api-gateway-dev.ab-inbev.cn',
    env: 'dev',
  },
  test: {
    baseURL: 'https://api-gateway-test.ab-inbev.cn',
    env: 'test',
  },
  uat: {
    baseURL: 'https://api-gateway-uat.ab-inbev.cn',
    env: 'uat',
  },
  prod: {
    baseURL: 'https://api-gateway.ab-inbev.cn',
    env: 'prod',
  },
  hotfix: {
    baseURL: 'https://api-gateway-hotfix.ab-inbev.cn',
    env: 'hotfix',
  },
  'feature-1': {
    baseURL: 'https://api-gateway-feature-1.ab-inbev.cn',
    env: 'feature-1',
  },
  'feature-2': {
    baseURL: 'https://api-gateway-feature-2.ab-inbev.cn',
    env: 'feature-2',
  },
};

export default config;
